/**
 * 列
 *
 * @Author: Shann
 * @LastEditors: Shann
 * @Date: 2021-07-23 07:49:31
 * @LastEditTime: 2021-07-23 09:45:03
 * @FilePath: \angular-js-for-bootstrap\src\spps\Col\Col.js
 * @Copyright: Copyright 2021-2021, all rights reserved. Essa.cn
 */
class Col {
  props = ["xs", "sm", "md", "lg"];

  state = ["className"];

  constructor() {
    this.state.className = ["col"];
    if (this.props.xs) {
      this.state.className.push("col-xs-" + this.props.xs);
    }
    if (this.props.sm) {
      this.state.className.push("col-sm-" + this.props.sm);
    }
    if (this.props.md) {
      this.state.className.push("col-md-" + this.props.md);
    }
    if (this.props.lg) {
      this.state.className.push("col-lg-" + this.props.lg);
    }
    this.state.className = this.state.className.join(" ");
  }
}
